﻿using System;
using System.Web.Mvc;
using System.ComponentModel.DataAnnotations;

namespace RedSand.Site.Models
{
    public class CategoryInfo
    {
        [Key]
        [HiddenInput(DisplayValue=false)]
        public int CategoryID{ get; set; }

        [Display(Name = "ParentID")]
        public int? ParentID{ get; set; }

        [Display(Name = "For custom pc")]
        public bool? ForCustomPc{ get; set; }

        [Display(Name = "Is custom pc")]
        public bool? IsCustomPc{ get; set; }

        [Display(Name = "Is Popular")]
        public bool? IsPopular{ get; set; }

        [Display(Name = "Order")]
        public int? Order{ get; set; }

        [Display(Name = "Name")]
        [Required]
        public string Name{ get; set; }

        [Display(Name = "Alias")]
        [RegularExpression(@"[a-zA-Z0-9_-]*")]
        [Required]
        public string Alias { get; set; }

        [Display(Name = "Image")]
        public string Image{ get; set; }

        [Display(Name = "Status")]
        public byte? Status{ get; set; }
    }
    public class PropertyInfo
    {
        [Key]
        [HiddenInput(DisplayValue = false)]
        public int PropertyID { get; set; }

        [Display(Name = "CategoryID")]
        public int? CategoryID { get; set; }

        [Display(Name = "Order")]
        public int? Order { get; set; }

        [Display(Name = "Name")]
        [Required]
        public string Name { get; set; }

        [Display(Name = "Status")]
        public byte? Status { get; set; }
    }
}
